<div class="fm-content">
  <!-- 最上面标题栏 -->
  <div class="title">
    <i nz-icon [type]="'desktop'"></i>
    &nbsp;&nbsp;携带小件行李旅客差异化通道数据采集记录表
  </div>
  <!-- 内容 -->
  <div class="work">

    <!-- 查询框 -->
    <div class="top">
    <!-- first-input -->

          <nz-select class="fm-input first-input" [(ngModel)]="fs.queryObject['subject']" (nzOpenChange)="cms_sjryDic.load('0')"
                     [nzPlaceHolder]="'受检人员'">
            <nz-option *ngFor="let option of cms_sjryDic.datas" [nzLabel]="option.display" [nzValue]="option.id">
            </nz-option>
            <nz-option *ngIf="cms_sjryDic.isLoading" nzDisabled nzCustomContent>
              <i nz-icon type="loading" class="loading-icon"></i>加载中...
            </nz-option>
          </nz-select>
          <nz-select class="fm-input" [(ngModel)]="fs.queryObject['channeltype']" (nzOpenChange)="cms_sjryDic.load('0')"
                     [nzPlaceHolder]="'通道类型'">
            <nz-option *ngFor="let option of cms_sjryDic.datas" [nzLabel]="option.display" [nzValue]="option.id">
            </nz-option>
            <nz-option *ngIf="cms_sjryDic.isLoading" nzDisabled nzCustomContent>
              <i nz-icon type="loading" class="loading-icon"></i>加载中...
            </nz-option>
          </nz-select>
          <div class="tool-left">
            <nz-button-group>
              <button nz-button nzType="primary" (click)="fs.loadData(true)">查询</button>
              <button nz-button (click)="fs.resetQueryObject() && fs.loadData(true)">重置</button>
            </nz-button-group>
          </div>
          <div class="tool-right">
            <nz-button-group>
              <button *ngIf="ss.mi.sa || ss.mi.xdxjxllktdxz" nz-button [nzType]="'primary'" (click)="editRow(null)">新增</button>
              <!-- <button nz-button (click)="fs.editRow()">编辑</button> -->
              <button *ngIf="ss.mi.sa || ss.mi.xdxjxllktdsc" nz-popconfirm nzTitle="确认删除选择项?" (nzOnConfirm)="fs.delEntitys()"
                      nzPlacement="bottomRight" nz-button>删除</button>
              <button nz-button (click)="fs.export('xjmh_xdxjxllktd.html', '小件行李旅客通道.xls')">导出</button>
              <nz-upload nzAction="{{ fs.getExcelUploadUrl() }}" [nzLimit]="1" [nzHeaders]="ffs.fileHeaders"
                         [nzFilter]="fs.excelFilters" [nzAccept]="'.xls,.xlsx'" (nzChange)="excelHandleChange($event)">
                <button *ngIf="ss.mi.sa || ss.mi.xdxjxllktdxz" nz-button>导入</button>
              </nz-upload>
            </nz-button-group>
          </div>
    </div>

    <!-- 右则样表单主体 -->
    <div class="work-content">
      <div class="table">
        <nz-table nzSize="middle" nzShowSizeChanger
        [nzPageSizeOptions]='[ 10, 15, 20, 30, 40, 50 ]'
        [nzFrontPagination]="false"
        [nzData]="fs.datas"
        [nzLoading]="fs.isLoading || fs.isDeleing"
        [nzTotal]="fs.rowsCount"
        [(nzPageIndex)]="fs.pageIndex"
        [(nzPageSize)]="fs.pageSize"
        (nzPageIndexChange)="fs.loadData()"
        (nzPageSizeChange)="fs.loadData(true)">
        <thead>
            <tr>
                <th nzShowCheckbox [(nzChecked)]="fs.allChecked"
                    [nzIndeterminate]="fs.indeterminate"
                    (nzCheckedChange)="fs.checkAll($event)"></th>
				<th nzWidth="10%">通道</th>
				<th nzWidth="10%">记录日期</th>
				<th nzWidth="10%">安检员数</th>
				<th nzWidth="10%">总受检人数</th>
				<th nzWidth="10%">总行李数</th>
				<th nzWidth="20%">手提行李安全检查设备</th>
				<th nzWidth="10%">通道类型</th>
				<th nzWidth="10%">通道运行状况</th>
				<th nzWidth="10%">备注</th>
            </tr>
        </thead>
        <tbody>
            <tr *ngFor="let data of fs.datas">
                <td nzShowCheckbox [(nzChecked)]="data.checked" (nzCheckedChange)="fs.refreshCheckStatus()">
                </td>
              <td><span (click)="editRow(data)" class="form-edit">{{data.channel}}</span></td>
				<td>{{data.recorddate | date:'yyyy-MM-dd' }}</td>
            		<td>{{data.screenerscount}}</td>
            		<td>{{data.subjectcount}}</td>
            		<td>{{data.suitcasescount}}</td>
				<td>{{data.equipmentName}}</td>
				<td>{{data.channeltypeName}}</td>
				<td>{{data.runningstatusName}}</td>
            		<td>{{data.remark}}</td>
            </tr>
        </tbody>
    </nz-table>
      </div>
    </div>

    <nz-modal nzWidth='830' nzTitle="编辑" [nzMaskClosable]='false'
        [nzFooter]="null"
        [(nzVisible)]="fs.isEditVisible"
        (nzOnCancel)="fs.closeEdit()" >
        <form nz-form [nzLayout]="'inline'">
			<div nz-row [nzGutter]="24">
                <div nz-col [nzSpan]="12">
                    <nz-form-item>
                        <nz-form-label nzRequired class="form-label">主键ID</nz-form-label>
                        <nz-form-control class="form-control" [nzValidateStatus]="id.invalid?'error':'success'" nzHasFeedback>
                            <input nz-input [(ngModel)]="fs.er.id"
                                	name="id" required #id="ngModel" />
                        </nz-form-control>
                    </nz-form-item>
                </div>
            </div>
			<div nz-row [nzGutter]="24">
                <div nz-col [nzSpan]="12">
                    <nz-form-item>
                        <nz-form-label nzRequired class="form-label">所属机场</nz-form-label>
                        <nz-form-control class="form-control" [nzValidateStatus]="airport.invalid?'error':'success'" nzHasFeedback>
                            <input nz-input [(ngModel)]="fs.er.airport"
                                	name="airport" required #airport="ngModel" />
                        </nz-form-control>
                    </nz-form-item>
                </div>
            </div>
			<div nz-row [nzGutter]="24">
                <div nz-col [nzSpan]="12">
                    <nz-form-item>
                        <nz-form-label nzRequired class="form-label">安全模式</nz-form-label>
                        <nz-form-control class="form-control" [nzValidateStatus]="securitymodel.invalid?'error':'success'" nzHasFeedback>
                            <input nz-input [(ngModel)]="fs.er.securitymodel"
                                	name="securitymodel" required #securitymodel="ngModel" />
                        </nz-form-control>
                    </nz-form-item>
                </div>
            </div>
			<div nz-row [nzGutter]="24">
                	<div nz-col [nzSpan]="12">
                    	<nz-form-item>
                        	<nz-form-label nzRequired class="form-label">记录日期</nz-form-label>
                        	<nz-form-control class="form-control" [nzValidateStatus]="recorddate.invalid?'error':'success'" nzHasFeedback>
                        		<nz-date-picker nzShowTime
                            		[(ngModel)]="fs.er.recorddate"
                                	name="recorddate" required #recorddate="ngModel"></nz-date-picker>
                        	</nz-form-control>
                    	</nz-form-item>
                	</div>
            	</div>
			<div nz-row [nzGutter]="24">
                	<div nz-col [nzSpan]="12">
                    	<nz-form-item>
                        	<nz-form-label nzRequired class="form-label">记录时间开始</nz-form-label>
                        	<nz-form-control class="form-control" [nzValidateStatus]="starttime.invalid?'error':'success'" nzHasFeedback>
                        		<nz-date-picker nzShowTime
                            		[(ngModel)]="fs.er.starttime"
                                	name="starttime" required #starttime="ngModel"></nz-date-picker>
                        	</nz-form-control>
                    	</nz-form-item>
                	</div>
            	</div>
			<div nz-row [nzGutter]="24">
                	<div nz-col [nzSpan]="12">
                    	<nz-form-item>
                        	<nz-form-label nzRequired class="form-label">记录时间结束</nz-form-label>
                        	<nz-form-control class="form-control" [nzValidateStatus]="endtime.invalid?'error':'success'" nzHasFeedback>
                        		<nz-date-picker nzShowTime
                            		[(ngModel)]="fs.er.endtime"
                                	name="endtime" required #endtime="ngModel"></nz-date-picker>
                        	</nz-form-control>
                    	</nz-form-item>
                	</div>
            	</div>
			<div nz-row [nzGutter]="24">
                <div nz-col [nzSpan]="12">
                    <nz-form-item>
                        <nz-form-label nzRequired class="form-label">受检人员</nz-form-label>
                        <nz-form-control class="form-control" [nzValidateStatus]="subject.invalid?'error':'success'" nzHasFeedback>
							<nz-select class="form-control" [(ngModel)]="fs.er.subject"
                                name="subject" required #subject="ngModel"
                                (nzOpenChange)="cms_sjryDic.load('0')" [nzPlaceHolder]="'请选择'">
							  <nz-option *ngFor="let option of cms_sjryDic.datas" [nzLabel]="option.display" [nzValue]="option.id">
							  </nz-option>
							  <nz-option *ngIf="cms_sjryDic.isLoading" nzDisabled nzCustomContent>
							    <i nz-icon type="loading" class="loading-icon"></i>加载中...
							  </nz-option>
							  <span *ngIf="!cms_sjryDic.isLoaded">
							    <nz-option [nzLabel]="fs.er.subjectName" [nzValue]="fs.er.subject">
							    </nz-option>
							  </span>
							</nz-select>
                        </nz-form-control>
                    </nz-form-item>
                	</div>
            </div>
			<div nz-row [nzGutter]="24">
                <div nz-col [nzSpan]="12">
                    <nz-form-item>
                        <nz-form-label nzRequired class="form-label">安检员数</nz-form-label>
                        <nz-form-control class="form-control" [nzValidateStatus]="screenerscount.invalid?'error':'success'" nzHasFeedback>
                            <nz-input-number [(ngModel)]="fs.er.screenerscount"
                                	name="screenerscount" required #screenerscount="ngModel"
                                	[nzMin]="1" [nzMax]="100" [nzStep]="1" class="form-control">
                            </nz-input-number>
                        </nz-form-control>
                    </nz-form-item>
                </div>
            </div>
			<div nz-row [nzGutter]="24">
                <div nz-col [nzSpan]="12">
                    <nz-form-item>
                        <nz-form-label nzRequired class="form-label">总受检人数</nz-form-label>
                        <nz-form-control class="form-control" [nzValidateStatus]="subjectcount.invalid?'error':'success'" nzHasFeedback>
                            <nz-input-number [(ngModel)]="fs.er.subjectcount"
                                	name="subjectcount" required #subjectcount="ngModel"
                                	[nzMin]="1" [nzMax]="100" [nzStep]="1" class="form-control">
                            </nz-input-number>
                        </nz-form-control>
                    </nz-form-item>
                </div>
            </div>
			<div nz-row [nzGutter]="24">
                <div nz-col [nzSpan]="12">
                    <nz-form-item>
                        <nz-form-label nzRequired class="form-label">总行李数</nz-form-label>
                        <nz-form-control class="form-control" [nzValidateStatus]="suitcasescount.invalid?'error':'success'" nzHasFeedback>
                            <nz-input-number [(ngModel)]="fs.er.suitcasescount"
                                	name="suitcasescount" required #suitcasescount="ngModel"
                                	[nzMin]="1" [nzMax]="100" [nzStep]="1" class="form-control">
                            </nz-input-number>
                        </nz-form-control>
                    </nz-form-item>
                </div>
            </div>
			<div nz-row [nzGutter]="24">
                <div nz-col [nzSpan]="12">
                    <nz-form-item>
                        <nz-form-label nzRequired class="form-label">无行李人数</nz-form-label>
                        <nz-form-control class="form-control" [nzValidateStatus]="nobaggage.invalid?'error':'success'" nzHasFeedback>
                            <nz-input-number [(ngModel)]="fs.er.nobaggage"
                                	name="nobaggage" required #nobaggage="ngModel"
                                	[nzMin]="1" [nzMax]="100" [nzStep]="1" class="form-control">
                            </nz-input-number>
                        </nz-form-control>
                    </nz-form-item>
                </div>
            </div>
			<div nz-row [nzGutter]="24">
                <div nz-col [nzSpan]="12">
                    <nz-form-item>
                        <nz-form-label nzRequired class="form-label">仅1件行李人数</nz-form-label>
                        <nz-form-control class="form-control" [nzValidateStatus]="onebaggage.invalid?'error':'success'" nzHasFeedback>
                            <nz-input-number [(ngModel)]="fs.er.onebaggage"
                                	name="onebaggage" required #onebaggage="ngModel"
                                	[nzMin]="1" [nzMax]="100" [nzStep]="1" class="form-control">
                            </nz-input-number>
                        </nz-form-control>
                    </nz-form-item>
                </div>
            </div>
			<div nz-row [nzGutter]="24">
                <div nz-col [nzSpan]="12">
                    <nz-form-item>
                        <nz-form-label nzRequired class="form-label">手提行李安全检查设备</nz-form-label>
                        <nz-form-control class="form-control" [nzValidateStatus]="equipment.invalid?'error':'success'" nzHasFeedback>
							<nz-select class="form-control" [(ngModel)]="fs.er.equipment"
                                name="equipment" required #equipment="ngModel"
                                (nzOpenChange)="cms_aqjcsbDic.load('0')" [nzPlaceHolder]="'请选择'">
							  <nz-option *ngFor="let option of cms_aqjcsbDic.datas" [nzLabel]="option.display" [nzValue]="option.id">
							  </nz-option>
							  <nz-option *ngIf="cms_aqjcsbDic.isLoading" nzDisabled nzCustomContent>
							    <i nz-icon type="loading" class="loading-icon"></i>加载中...
							  </nz-option>
							  <span *ngIf="!cms_aqjcsbDic.isLoaded">
							    <nz-option [nzLabel]="fs.er.equipmentName" [nzValue]="fs.er.equipment">
							    </nz-option>
							  </span>
							</nz-select>
                        </nz-form-control>
                    </nz-form-item>
                	</div>
            </div>
			<div nz-row [nzGutter]="24">
                <div nz-col [nzSpan]="12">
                    <nz-form-item>
                        <nz-form-label nzRequired class="form-label">通道类型</nz-form-label>
                        <nz-form-control class="form-control" [nzValidateStatus]="channeltype.invalid?'error':'success'" nzHasFeedback>
							<nz-select class="form-control" [(ngModel)]="fs.er.channeltype"
                                name="channeltype" required #channeltype="ngModel"
                                (nzOpenChange)="cms_sjryDic.load('0')" [nzPlaceHolder]="'请选择'">
							  <nz-option *ngFor="let option of cms_sjryDic.datas" [nzLabel]="option.display" [nzValue]="option.id">
							  </nz-option>
							  <nz-option *ngIf="cms_sjryDic.isLoading" nzDisabled nzCustomContent>
							    <i nz-icon type="loading" class="loading-icon"></i>加载中...
							  </nz-option>
							  <span *ngIf="!cms_sjryDic.isLoaded">
							    <nz-option [nzLabel]="fs.er.channeltypeName" [nzValue]="fs.er.channeltype">
							    </nz-option>
							  </span>
							</nz-select>
                        </nz-form-control>
                    </nz-form-item>
                	</div>
            </div>
			<div nz-row [nzGutter]="24">
                <div nz-col [nzSpan]="12">
                    <nz-form-item>
                        <nz-form-label nzRequired class="form-label">通过率</nz-form-label>
                        <nz-form-control class="form-control" [nzValidateStatus]="passrate.invalid?'error':'success'" nzHasFeedback>
                            <input nz-input [(ngModel)]="fs.er.passrate"
                                	name="passrate" required #passrate="ngModel" />
                        </nz-form-control>
                    </nz-form-item>
                </div>
            </div>
			<div nz-row [nzGutter]="24">
                <div nz-col [nzSpan]="12">
                    <nz-form-item>
                        <nz-form-label nzRequired class="form-label">开包率</nz-form-label>
                        <nz-form-control class="form-control" [nzValidateStatus]="unpackrate.invalid?'error':'success'" nzHasFeedback>
                            <input nz-input [(ngModel)]="fs.er.unpackrate"
                                	name="unpackrate" required #unpackrate="ngModel" />
                        </nz-form-control>
                    </nz-form-item>
                </div>
            </div>
			<div nz-row [nzGutter]="24">
                <div nz-col [nzSpan]="12">
                    <nz-form-item>
                        <nz-form-label nzRequired class="form-label">复检率</nz-form-label>
                        <nz-form-control class="form-control" [nzValidateStatus]="retestrate.invalid?'error':'success'" nzHasFeedback>
                            <input nz-input [(ngModel)]="fs.er.retestrate"
                                	name="retestrate" required #retestrate="ngModel" />
                        </nz-form-control>
                    </nz-form-item>
                </div>
            </div>
			<div nz-row [nzGutter]="24">
                <div nz-col [nzSpan]="12">
                    <nz-form-item>
                        <nz-form-label nzRequired class="form-label">通道运行状况</nz-form-label>
                        <nz-form-control class="form-control" [nzValidateStatus]="runningstatus.invalid?'error':'success'" nzHasFeedback>
							<nz-select class="form-control" [(ngModel)]="fs.er.runningstatus"
                                name="runningstatus" required #runningstatus="ngModel"
                                (nzOpenChange)="cms_tdyxzkDic.load('0')" [nzPlaceHolder]="'请选择'">
							  <nz-option *ngFor="let option of cms_tdyxzkDic.datas" [nzLabel]="option.display" [nzValue]="option.id">
							  </nz-option>
							  <nz-option *ngIf="cms_tdyxzkDic.isLoading" nzDisabled nzCustomContent>
							    <i nz-icon type="loading" class="loading-icon"></i>加载中...
							  </nz-option>
							  <span *ngIf="!cms_tdyxzkDic.isLoaded">
							    <nz-option [nzLabel]="fs.er.runningstatusName" [nzValue]="fs.er.runningstatus">
							    </nz-option>
							  </span>
							</nz-select>
                        </nz-form-control>
                    </nz-form-item>
                	</div>
            </div>
			<div nz-row [nzGutter]="24">
                <div nz-col [nzSpan]="12">
                    <nz-form-item>
                        <nz-form-label nzRequired class="form-label">备注</nz-form-label>
                        <nz-form-control class="form-control" [nzValidateStatus]="remark.invalid?'error':'success'" nzHasFeedback>
                            <input nz-input [(ngModel)]="fs.er.remark"
                                	name="remark" required #remark="ngModel" />
                        </nz-form-control>
                    </nz-form-item>
                </div>
            </div>
			<div nz-row [nzGutter]="24">
                <div nz-col [nzSpan]="12">
                    <nz-form-item>
                        <nz-form-label nzRequired class="form-label">记录人员签字</nz-form-label>
                        <nz-form-control class="form-control" [nzValidateStatus]="signature.invalid?'error':'success'" nzHasFeedback>
                            <input nz-input [(ngModel)]="fs.er.signature"
                                	name="signature" required #signature="ngModel" />
                        </nz-form-control>
                    </nz-form-item>
                </div>
            </div>
           	<div nz-row [nzGutter]="24">
                <div nz-col [nzSpan]="24" class="form-button-align">
                    <button nz-button nzType="default" (click)="fs.closeEdit()" class="form-button">取消</button>
                    <button nz-button nzType="primary"
                    		[disabled]='true'
                        	(click)="fs.save()" [nzLoading]="fs.isSaveing">保存</button>
                </div>
            </div>
        </form>
    </nz-modal>
  </div>
</div>
